/* Site details */

.site-info-panel {
	--padding-size: 24px;

	background: #ffffff;
	box-shadow: 0px 5px 15px rgba(0, 0, 0, 0.08);
	border-radius: var(--site-manager-border-radius);
	overflow: hidden;

	display: flex;
	flex-direction: column;
	flex-grow: 1;
}

.site-info-panel-content {
	min-height: 0;
}

.padded {
	padding: var(--padding-size);
}

.tabs {
	width: 100%;
	height: 100%;
	display: flex;
	flex-direction: column;

	& :global(.components-tab-panel__tabs) {
		--wp-components-color-accent: var(--color-gray-900);
		border-bottom: 1px solid var(--color-gray-200);
	}
	& :global(.components-tab-panel__tabs-item) {
		padding-left: var(--padding-size);
		padding-right: var(--padding-size);
	}
	& :global(.components-tab-panel__tab-content) {
		display: flex;
		flex-direction: column;
		flex-grow: 1;
		min-height: 0;
		overflow: hidden;
		align-self: stretch;
	}
}

.tab-contents {
	width: 100%;
	display: flex;
	flex-direction: column;
	flex: 1;
	min-height: 0;
	position: relative;
	overflow: auto;
}

.tabHidden {
	display: none !important;
}

.file-browser-tab {
	overflow: hidden;
}

/**
 * A workaround for scrolling overflowing content within
 * a flex container. TODO: find a way to avoid using
 * position: absolute.
 */
.logs-wrapper {
	display: block;
}

.site-notice {
	padding: var(--padding-size);
	:global(& .components-notice__content) {
		margin: 0;
	}
}

.section-title {
	color: var(--color-gray-900);
	padding: 0;
	margin: 0;
	font-size: 14px;
	line-height: 20px; /* 142.857% */
}

.gray-link {
	color: var(--color-gray-600) !important;
}

.gray-link-dark {
	color: var(--color-gray-900) !important;
}

.button-no-padding {
	padding-left: 0 !important;
	padding-right: 0 !important;
}

.logs-section {
	display: flex;
	height: 100%;
	flex-direction: column;
	width: 100%;
}

.site-info-header {
	color: inherit;

	&:has(.site-info-header-details-created-at:empty),
	&:not(:has(.site-info-header-details-created-at)) {
		justify-content: center;
		align-items: center;
	}
}

.site-info-header-icon {
	box-sizing: border-box;

	width: 48px;
	height: 48px;
	margin-right: 8px;

	background: #ffffff;
	border: 1px solid rgba(0, 0, 0, 0.1);
	border-radius: 4px;

	flex: none;
	flex-grow: 0;
}

.site-info-header-icon-default {
	width: 100%;
	height: 100%;
	path {
		/* TODO: Confirm or switch color */
		fill: black;
	}
}

.site-info-header-details-name {
	margin: 0;

	/* Inside auto layout */
	font-size: clamp(14px, 2.5vw, 18px);
	line-height: 24px;
	font-weight: 500;
	/* identical to box height, or 150% */
	letter-spacing: -0.01em;

	/* Gutenberg/Gray 900 */
	color: var(--color-gray-900);

	display: flex;
	align-items: baseline;
	gap: 0;
	flex-wrap: nowrap;
	max-width: 100%;
}

.siteInfoHeaderTitle {
	min-width: 0;
	flex: 1 1 auto;
}

.siteInfoHeaderDetailsNameText {
	flex: 0 1 auto;
	min-width: 0;
	text-overflow: ellipsis;
	word-break: break-word;
}

.siteInfoRenameButton {
	vertical-align: middle;
}

.siteInfoHeaderDetailsNameTextEnd {
	white-space: nowrap;
}

.site-info-header-details-created-at {
	width: 100%;
	font-size: 14px;
	line-height: 20px;
	/* identical to box height, or 154% */

	/* Gutenberg/Gray 700 */
	color: #757575;
}

.siteInfoHeaderTitleRow {
	align-items: flex-start;
	gap: 8px;
}

.siteInfoHeaderPrimaryActions {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	align-items: stretch;
	gap: 8px;
	flex: 0 1 auto;
	min-width: 0;
}

.siteInfoHeaderAction {
	flex: none;
	flex-shrink: 0;
}

.siteInfoRenameButton {
	padding: 2px !important;
	min-height: 24px;

	flex: 0 0 auto;
	margin-left: 4px;
	position: static;
	white-space: nowrap;
	display: inline-flex;
	align-items: center;
}

.siteInfoRenameButton :global(svg) {
	width: 16px;
	height: 16px;
}

.max-width {
	width: 100%;
}

.danger {
	color: var(--color-alert-red);
}

.blueprint-wrapper {
	display: flex;
	flex-direction: column;
	height: 100%;
	min-height: 0;
}

.blueprint-header {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 12px;
	padding: 10px 20px 10px 16px;
	border-bottom: 1px solid var(--color-gray-200);
	background: #ffffff;
	flex-wrap: wrap;
}

.blueprint-header :global(.components-button) {
	height: 32px;
	flex-shrink: 0;
	margin-right: -8px;
}

.blueprint-header :global(.components-checkbox-control) {
	margin: 0;
}

.blueprint-header :global(.components-base-control__field) {
	margin-bottom: 0;
}
.blueprint-header :global(.components-checkbox-control__label) {
	font-size: 13px;
}

.blueprint-header :global(.components-base-control__help) {
	display: none;
}

.playIcon {
	width: 18px;
	height: 18px;
	margin-right: 6px;
}

.blueprint-editor {
	flex: 1;
	min-height: 0;
	overflow: auto;
	background: #ffffff;
}

.blueprint-editor :global(.cm-editor) {
	height: 100%;
}

.blueprint-editor :global(.cm-scroller) {
	overflow: auto;
}

.blueprintNotice {
	padding: 12px 16px;
	background: #f0f6fc;
	border-bottom: 1px solid var(--color-gray-200);
	font-size: 13px;
	color: var(--color-gray-700);
	line-height: 1.5;
}

@media (max-width: 600px) {
	.blueprint-header {
		padding: 8px 0 8px 12px;
		gap: 8px;
		flex-direction: column-reverse;
		align-items: stretch;
	}

	.blueprint-header :global(.components-button) {
		width: 100%;
		margin-right: -8px;
	}

	.blueprint-header :global(.components-checkbox-control) {
		width: 100%;
		padding-right: 12px;
	}
}
